package vn.vietel.pms.entity;

import java.io.Serializable;
import static org.jboss.seam.ScopeType.EVENT;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.validator.NotNull;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.annotations.Scope;

@Entity
@Name("vbtsstation")
@Scope(EVENT)
@Table(name = "VBTSStation")
public class VBTSStation implements Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = -4420748266420770411L;

	private Long id;
	private String btsName;
	private String btsLocation;
	private Double btsCapacity;
	private Boolean btsStatus;
	private Double btsUsed;

	private VTeam btsBelongTo;

	public VBTSStation() {
		super();
	}

	public VBTSStation(String btsName, String btsLocation, VTeam btsBelongTo,
			Double btsCapacity, Boolean btsStatus, Double btsUsed) {
		super();
		this.btsName = btsName;
		this.btsLocation = btsLocation;
		this.btsBelongTo = btsBelongTo;
		this.btsCapacity = btsCapacity;
		this.btsStatus = btsStatus;
		this.btsUsed = btsUsed;
	}

	@Id
	@Column(name = "stationId")
	@GeneratedValue(strategy = GenerationType.AUTO)
	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	@NotNull
	public String getBtsName() {
		return btsName;
	}

	public void setBtsName(String btsName) {
		this.btsName = btsName;
	}

	public String getBtsLocation() {
		return btsLocation;
	}

	public void setBtsLocation(String btsLocation) {
		this.btsLocation = btsLocation;
	}

	@ManyToOne(cascade = CascadeType.PERSIST)
	@JoinColumn(name = "teamId")
	public VTeam getBtsBelongTo() {
		return btsBelongTo;
	}

	public void setBtsBelongTo(VTeam btsBelongTo) {
		this.btsBelongTo = btsBelongTo;
	}

	public Double getBtsCapacity() {
		return btsCapacity;
	}

	public void setBtsCapacity(Double btsCapacity) {
		this.btsCapacity = btsCapacity;
	}

	public Boolean getBtsStatus() {
		return btsStatus;
	}

	public void setBtsStatus(Boolean btsStatus) {
		this.btsStatus = btsStatus;
	}

	public Double getBtsUsed() {
		return btsUsed;
	}

	public void setBtsUsed(Double btsUsed) {
		this.btsUsed = btsUsed;
	}

}
